package com.aizhixin.lab.task.repository;

import com.aizhixin.lab.task.entity.TaskQuestion;

import java.util.List;

import org.springframework.data.jpa.repository.JpaRepository;


public interface TaskQuestionRepository extends JpaRepository<TaskQuestion, String> {
	 TaskQuestion findByIdAndDeleteFlag(String id,Integer deleteFlag);
	 TaskQuestion findByTaskIdAndOrderNumAndDeleteFlag(String taskId,Integer orderNum,Integer deleteFlag);
	 List<TaskQuestion> findByTaskIdAndDeleteFlagOrderByOrderNumAsc(String taskId,Integer deleteFlag);
	 List<TaskQuestion> findByTaskIdInAndDeleteFlag(List<String> taskIds,Integer deleteFlag);
	 Integer countByTaskIdAndDeleteFlag(String taskId,Integer deleteFlag);
	 void deleteByTaskId(String taskId);
}
